# @summary A short summary of the purpose of this class
#
# A description of what this class does
#
# @example
#   include wn9metapkg
class wn9metapkg (
  Array[String]    $extra_pkg              = [],
  Boolean          $xwindows               = false,
  Array[String]    $extra_pkggroup         = [],
  Boolean          $enable_kerneldebug     = false,
  Boolean          $enable_castor          = false,
){
  if $xwindows {
    $xwingroups=[
     "Server with GUI",
     #"KDE",
     "GNOME",
    ]

    yum::group { $xwingroups:
      ensure => present,
    }
  }

  if size($extra_pkggroup)>=1 {
    yum::group { $extra_pkggroup:
       ensure => present,
     }
  }
  case $facts['os']['architecture'] {
  "x86_64":{
      package { "wn9pkg":
        ensure  => "latest",
        require => Yumrepo['site'],
      }
    }
  "aarch64":{
      package { "wn9pkg":
        ensure  => "installed",
        require => Yumrepo['site'],
      }
    }
  }
  if size($extra_pkg)>=1 {
    package { $extra_pkg:
      ensure  => "installed",
      require => Package[$wnpkg]
    }
  }

  #@contain wn9metapkg::packages

  #Class['wn9metapkg::packages']
  #include '::wn9metapkg::packages'
}
